import VueRouter from 'vue-router'

import home from './components/tabbar/Home.vue'
import member from './components/tabbar/member.vue'
import cart from './components/tabbar/cart.vue'
import search from './components/tabbar/search.vue'
import news from './components/new/New.vue'
import newsInfo from'./components/new/NewsInfo.vue'
import photosList from './components/photo/photosLits.vue'
import photoInfo from './components/photo/photoInfo.vue'
import goodList from './components/goods/goodsList.vue'
import goodinfo from './components/goods/goodsInfo.vue'
import goodDesc from './components/goods/goodDesc.vue'
import goodComment from './components/goods/goodComment.vue'

var router = new VueRouter({
    routes:[
        {path:'/',redirect:'/home'},
        {path:'/home',component:home},
        {path:'/member',component:member},
        {path:'/cart',component:cart},
        {path:'/search',component:search},
        {path:'/home/news',component:news},
        {path:'/home/newsinfo/:id',component:newsInfo},
        {path:'/home/pic',component:photosList},
        {path:'/home/photoInfo/:id',component:photoInfo},
        {path:'/home/goodlist',component:goodList},
        {path:'/home/goodinfo/:id',component:goodinfo},
        {path:'/home/gooddesc/:id',component:goodDesc},
        {path:'/home/goodcomment/:id',component:goodComment},
    ],
    linkActiveClass: 'mui-active'
});
export default router